package 函数式接口.获取Stream流;

import java.util.ArrayList;
import java.util.List;
import java.util.stream.Stream;

public class Test01 {

    public static void main(String[] args) {
        System.out.println("获取Stream流");

        // Collection接口的stream()方法

        List<String> list = new ArrayList<>();
        list.add("张三");
        list.add("李四");
        list.add("王五");

        Stream<String> stream = list.stream();


        Stream<String> stringStream = Stream.of("张三", "李四", "王五");
    }
}
